package com.waiting.leetcode;

import java.util.HashSet;
import java.util.Set;

/**
 * @Description
 * @Author bjweitingting
 * @Date 2019/1/31
 **/
public class JEwelasAndStones771 {
    public static void main(String[] args) {
        char []test ={'a','b'};
        System.out.println(Character.codePointAt(test,0,2));
    }

    public int one(String J, String s) {
        int result = 0;
        Set<Character> je = new HashSet<>();
        for (char c : J.toCharArray()) {
            je.add(c);
        }
        return result;
    }

    public int two(String J, String s) {
        int result = 0;
        Set<Character> je = new HashSet<>();

        for (int i = 0; i < J.length(); i++) {
            je.add(J.charAt(i));
        }
        return result;
    }
}
